def homework1(name,age,address='',gender=True):
    """
    多个缺省参数的传递练习，练习多个缺省参数
    """
    gender_text = '男'

    if not gender:
        gender_text = '女'
    print("%s 性别%s，年龄是%s,住址是%s"% (name, gender_text,age, address))


def homework2(*args, **kwargs):
    """
    多值参数练习，元组，字典的传参拆包练习
    :param args:
    :param kwargs:
    :return:
    """
    print(f'多值参数-{args}')
    print(f'字典型多值参数-{kwargs}')
    homework2_pass(*args, **kwargs)

def homework2_pass(* args, **kwargs):
    print(f'传参后的元组参数-{args}')
    print(f'传参后的字典参数-{kwargs}')

class Dog:
    """
    设计一个类，实例化1个对象，会实现下面两种行为
    需求
    •一只 黄颜色 的 狗狗 叫 大黄
    •具有  汪汪叫 行为
    •具有  摇尾巴 行为
    :return:
    """
    def __init__(self, name, color):
        self.name = name
        self.color = color

    def bark(self):
        print(f'{self.name} 汪汪叫')

    def wag_tail(self):
        print(f'{self.name} 摇尾巴')





if __name__ == '__main__':
    homework1('张三',25)
    homework1('李四',30,'北京')
    homework1('李四',26,gender=False)
    print('-'*50)
    homework2(1,2,3,4,5, name='张三', age=25, address='北京')
    print('-'*50)

    dog = Dog('大黄', '黄色')
    dog.bark()
    dog.wag_tail()